<template>
  <div class="topNav">
    <Row class="nav">
      <i-col class="navLeft" span="10">

          <div class="logo">
            <a href="javascript:;">
              <img src=".././assets/rcmtm.png" alt="rcmtm客服中心" title="rcmtm客服中心">
            </a>
          </div>
          <span>|</span>
          <h3>客服中心</h3>
      </i-col>
      <i-col class="navRight" span="14">
        <Menu mode="horizontal" theme="light" active-name="1">
            <MenuItem name="1" >
              <a href="javascript:;" @click="toIndex">首页</a>
              <span></span>
            </MenuItem>
            <MenuItem name="2" >
              <a href="javascript:;" @click="toSimProblem">常见问题</a>
              <span></span>
            </MenuItem>
            <MenuItem name="3">
              <a href="javascript:;" @click="toServeRecord">服务记录</a>
              <span></span>
            </MenuItem>
            <Submenu name="4">
              <template slot="title">中文</template>
              <MenuItem name="4-1">中文</MenuItem>
              <MenuItem name="4-2">英文</MenuItem>
            </Submenu>
        </Menu>
      </i-col>
    </Row>
  </div>
</template>
<script scoped>
  export default {
    name: 'header',
    data () {
      return {
        msg: 'header'
      }
    },
    methods:{
        //首页
        toIndex(){
            this.$router.push({
              path: '/'
            });
        },
        //常见问题
        toSimProblem(){
            this.$router.push("/simProblem");
        },
        //服务记录
        toServeRecord(){
            this.$router.push("/ServeRecord")
        }
    }
  }
</script>
<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped>
  .topNav{
    background: #fff;
  }
  .nav{
    margin: 0 auto;
    width:1120px;
  }
  /*头部左侧*/
  .navLeft{
    display: flex;
  }
  .navLeft>.logo{
    width:100px;
    height:40px;
    margin: 15px 0;
  }
  .navLeft>.logo img {
    width: 100px;
    height: 40px;
  }
  .navLeft>h3{
    line-height: 70px;
    font-size: 15px;
    font-weight: normal;
    color: #464c5b;
    opacity: 0.5;
    cursor: pointer;
  }
  .navLeft>span{
    font-size: 18px;
    color: #464c5b;
    opacity: 0.5;
    margin: 0 20px;
    line-height: 70px;
  }
  /*头部右侧导航*/
  .navRight>.ivu-menu{
    float: right;
    height:70px;
    line-height: 70px;
  }
  .navRight>.ivu-menu>.ivu-menu-item{
    width:130px;
    text-align: center;
    color:#464c5b;
    border-bottom: 2px solid transparent;
    font-size: 16px;
  }
  .navRight>.ivu-menu>.ivu-menu-submenu-title{
    color:#464c5b;
  }
  .navRight>.ivu-menu>.ivu-menu-item>a{
    display: block;
    color:#464c5b;
  }
  /*导航下划线 span*/
  .navRight>.ivu-menu>.ivu-menu-item>span{
    display: none;
    width: 40px;
    height: 2px;
    background: #464c5b;
    margin: 0 auto;
  }
  .ivu-menu-horizontal .ivu-menu-item-active>span,
  .ivu-menu-horizontal .ivu-menu-item:hover span,
  .ivu-menu-horizontal .ivu-menu-submenu-active>span,
  .ivu-menu-horizontal .ivu-menu-submenu:hover span{
    display: block !important;
  }
  /*去掉ivew默认导航边框*/
  .ivu-menu-horizontal.ivu-menu-light:after{
    height: 0;
  }
  /*去掉iview导航默认下划线*/
  .ivu-menu-light.ivu-menu-horizontal .ivu-menu-item-active,
  .ivu-menu-light.ivu-menu-horizontal .ivu-menu-item:hover,
  .ivu-menu-light.ivu-menu-horizontal .ivu-menu-submenu-active,
  .ivu-menu-light.ivu-menu-horizontal .ivu-menu-submenu:hover{
    color: #464c5b;
    border-bottom: none;
  }
  .ivu-menu-light.ivu-menu-horizontal .ivu-menu-item, .ivu-menu-light.ivu-menu-horizontal .ivu-menu-submenu{
    border-bottom: none;
  }
</style>
